package cn.bgs.service.impl;

import cn.bgs.dao.StudentInformationMapper;
import cn.bgs.pojo.*;
import cn.bgs.service.StudentInformationService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/*
@Auther ysr  
@Date 2021/7/15
@Time 20:20
*/
@Service
public class StudentInformationServiceImpl implements StudentInformationService {
    @Autowired
    private StudentInformationMapper studentInformationMapper;

    @Override
    public List<StudentInformation> findStudentInformation(String stuName, String mobile, String sex, Integer age, String idNum, String gradeName) {
        return studentInformationMapper.findStudentInformation(stuName,mobile,sex,age,idNum,gradeName);
    }
    @Override
    public List<Student> findStudent(StudentInformation studentInformation) {
        return studentInformationMapper.findStudent(studentInformation);
    }
    @Override
    public Integer studentDelete(Integer stuId) {
        return studentInformationMapper.studentDelete(stuId);
    }

    @Override
    public StudentInformation updateView(Integer stuId) {
        return studentInformationMapper.updateView(stuId);
    }

    @Override
    public List<Provinces> provinces() {
        return studentInformationMapper.provinces();
    }

    @Override
    public List<Cities> cities() {
        return studentInformationMapper.cities();
    }

    @Override
    public List<Areas> areas() {
        return studentInformationMapper.areas();
    }

    @Override
    public Integer updateStu(StudentInformation stu) {
        return studentInformationMapper.updateByPrimaryKeySelective(stu);
    }

    @Override
    public Integer insertStu(StudentInformation stu) {
        return studentInformationMapper.insertSelective(stu);
    }

    @Override
    public Integer deleteList(List<Integer> list) {
        return studentInformationMapper.deleteList(list);
    }

    @Override
    public List<StudentInformation> findGradeStu(String gradeName) {
        return studentInformationMapper.findGradeStu(gradeName);
    }

    @Override
    public List<StudentInformation> findDormitoryStu(String dormitoryName) {
        return studentInformationMapper.findDormitoryStu(dormitoryName);
    }

    @Override
    public Integer updatestuName(StudentInformation studentInformation) {
        return studentInformationMapper.updatestuName(studentInformation);
    }

    @Override
    public Integer insertAddStu(StudentInformation studentInformation) {
        return studentInformationMapper.insertAddStu(studentInformation);
    }

    @Override
    public Integer insertAdd(StudentInformation studentInformation) {
        return studentInformationMapper.insertAdd(studentInformation);
    }


}
